<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>内外边距</title>
    <style>
        * {
            /* 清除默认的内外边距 
            浏览器中都有默认的内外边距
            如body标签默认margin：8px
            p标签默认有上下的margin
            ul标签有默认有上下的margin和padding-left
            */
            padding: auto;
            margin: auto;
        }
        div {
            width: 1000px;
            height: 300px;
            background-color: pink;
            margin: 0 auto;
        }

    </style>
</head>
<body>
    <p>ppp</p>
    <p>0000</p>
    <h1>h1</h1>
    <ul>
        <li>111</li>
    </ul><br><hr>
    <div>版心</div>
</body>
</html>